package com.example.demo;

import com.example.demo.filter.MyFilter;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.netflix.zuul.EnableZuulProxy;
import org.springframework.context.annotation.Bean;

@SpringBootApplication
@EnableZuulProxy
@EnableDiscoveryClient // zuul本身没有包含服务发现
public class Zuul9527Application {

//    @Bean
//    @LoadBalanced
//    public RestTemplate rt(){
//        return new RestTemplate();
//    }

    @Bean
    public MyFilter myFilter(){
        return new MyFilter();
    }

    public static void main(String[] args) {
        SpringApplication.run(Zuul9527Application.class, args);
    }
}
